#include "TextField.h"

TextField::TextField(void)
{
}

TextField::TextField(BITMAP *_dest, int _x, int _y, unsigned int _width, unsigned int _height, bool _alphaBlended):
Sprite(NULL, _dest, _x, _y, _width, _height, _alphaBlended),
color(0)
{
	strcpy(text, "");
}

TextField::~TextField(void)
{

}

void TextField::draw()
{
	if(visible)
		textprintf_ex(dest, font, x, y, color, -1, "%s", text);
}

/*void TextField::setText(char *t)
{
	strcpy(text, t);
}

void TextField::setText(std::string s)
{
	strcpy
}

void TextField::setText(unsigned int i)
{
	//itoa(i, text);
	sprintf(text, "%i", i);
}*/
